package main

import (
	"github.com/astaxie/beego"
	"github.com/astaxie/beego/orm"
	"golang-blog/controllers/blog"
	_ "golang-blog/filter"
	"golang-blog/models"
	_ "golang-blog/routers"
)

func init() {
	//注册数据库
	models.RegDB()
}
func main() {
	orm.Debug = true
	orm.RunSyncdb("default", false, true)
	beego.ErrorController(&blog.ErrorController{})
	beego.Run()
}
